package com.jf.hotelreservation.demos.controller;

import com.jf.hotelreservation.demos.service.impl.LoginServiceImpl;
import com.jf.hotelreservation.demos.utils.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class LoginController {

    @Autowired
    private LoginServiceImpl loginService;

    @RequestMapping("/login")
    public R login(String username, String password){
        return loginService.login(username, password);
    }
}
